<%-- 
    Document   : index
    Created on : 14/07/2011, 20:03:14
    Author     : Ramon Moraes
--%>

<%@page import="javax.persistence.Persistence"%>
<%@page import="javax.persistence.EntityManager"%>
<%@page import="javax.persistence.EntityManagerFactory"%>
<%@page import="java.util.Properties"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
   <head>
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      <title>JSP Page</title>
   </head>
   <body>
      <%
         Properties p = new Properties();
         p.setProperty("hibernate.hbm2ddl.auto", "create");
         EntityManagerFactory emf = Persistence.createEntityManagerFactory("portalPU");

         EntityManager em = emf.createEntityManager();

         em.close();
         emf.close();
      %>
      <h1>banco gerado com sucesso</h1>
   </body>
</html>
